// 1 + 1/2 + 1/3 + ... + 1/n 

#include <iostream>

int main()
{
	int n = 1;
	
	std::cout << "Enter number: n = ";
	
	do
	{
		std::cin >> n;
	}
	while
		(n <= 0);

	double sum = 1;

	std::cout << "1";

	for(int i = 2; i <= n; ++i)
    {
		sum += 1 / (double)i;
		std::cout << " + 1/" << i;
	}

	std::cout << " = " << sum << std::endl;
	
	return 0;
}
